// import Vue from 'vue'; //引入vue
// //必须实例化 Vue
// let vm = new Vue();
// // 获取Promise对象的值
// export function commonGetJumpTimes() {
//     let jumpTmFun = vm.GLOBAL.getJumpTime();
//     let times = 0;
//     jumpTmFun.then((resData) => {
//         times = resData.data;
//     });
//     return 20;
// }
export function getTypeMobile() {
    var equipmentType = "";
    var agent = navigator.userAgent.toLowerCase();
    var android = agent.indexOf("android");
    var iphone = agent.indexOf("iphone");
    var ipad = agent.indexOf("ipad");
    if (android != -1) {
        equipmentType = "android";
    }
    if (iphone != -1 || ipad != -1) {
        equipmentType = "ios";
    }
    return equipmentType

}
/**
 * 
 * @returns 
 */
var isPc;
//判断是否移动端访问
export function isPC() {
    const userAgentInfo = navigator.userAgent;
    console.log(userAgentInfo);
    const Agents = new Array(
        "Android",
        "iPhone",
        "SymbianOS",
        "Windows Phone",
        "iPad",
        "iPod"
    );
    for (let v = 0; v < Agents.length; v++) {
        if (userAgentInfo.indexOf(Agents[v]) > 0) {
            isPc = false;
            break;
        }
    }
};
export function getClientHeight() {
    let mobileObj = {};
    let isIos = '';
    mobileObj.vHeight = parseInt(document.documentElement.clientHeight);
    mobileObj.vWidth = parseInt(document.documentElement.clientWidth);
    mobileObj.screenHeight = parseInt(
        window.screen.availHeight * window.devicePixelRatio
    );
    mobileObj.screenWidth = parseInt(
        window.screen.availWidth * window.devicePixelRatio
    );
    mobileObj.boxWidth = parseInt(3.33 * mobileObj.vHeight);
    mobileObj.boxHeight = parseInt(3.33 * mobileObj.vWidth);
    // isIos = getTypeMobile();
    // console.log('IOS???',  isIos)

    // console.log(
    //     "分辨率22????",
    //     mobileObj.screenHeight,
    //     mobileObj.screenWidth,
    //     window.devicePixelRatio
    // );
    return mobileObj
};
/**
 * 
 *   
 */



